// tips: 如果是单独实例允许需要注释这一行
import "./set-public-path"; 

import Vue from 'vue'
import App from './App.vue'
import {initRouter} from './router'

import store from './store'
import '@/mock'
import 'moment/locale/zh-cn'
import Antd from 'ant-design-vue';
import 'ant-design-vue/dist/antd.css';
import bootstrap2 from '@/bootstrap'
import {initI18n} from '@/utils/i18n'


import singleSpaVue from "single-spa-vue";

const i18n = initI18n('CN', 'US')
const router = initRouter(store.state.setting.asyncRoutes)


Vue.use(Antd);

Vue.config.productionTip = false

bootstrap2({router, store, i18n, message: Vue.prototype.$message})

// new Vue({
//   router,
//   store,
//   render: h => h(App)
// }).$mount('#app')



// tips: 如果是单独实例允许需要注释以下内容
const vueLifecycles = singleSpaVue({
  Vue,
  appOptions: {
    render(h) {
      return h(App, { props: { githubLink: this.githubLink } });
    },
    router,
    store,
    i18n,
  },
});

export const bootstrap = vueLifecycles.bootstrap;
export const mount = vueLifecycles.mount;
export const unmount = vueLifecycles.unmount;